/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package lib;

import java.util.*;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
import java.net.*;

/**
 *
 * @author felipe
 */
public class Session {

    public HttpSession session;

    public Session()
    {
        
    }

    public Session(HttpServletRequest request) throws ServletException, IOException
    {
        this.session = request.getSession();
    }

    public void createSession(HttpServletRequest request) throws ServletException, IOException
    {
        this.session = request.getSession();
    }

    public void setSession(String name, Object value)
    {
        this.session.setAttribute(name, value);
    }

    public Object getSession(String name)
    {
        return this.session.getAttribute(name) ;
    }

    public void deleteSession(String name)
    {
        this.session.removeAttribute(name);
    }

    public void clearSession()
    {
       
    }

}
